Browser-Specific Stuff
A lot of what we now consider "standard" HTML
(tables, text around graphics, centering) started out as Netscape-specific
features. Much of it has been absorbed in the yet-to-be-nailed HTML 3.2
specification, and adopted by other browser makers,
so you can use it and be relatively sure it is supported
by the people who read your pages.
However, there are features supported by Netscape and Internet Explorer
that haven't (yet) been absorbed into the standard. There are a few
situations where you might want to use them, but remember that A) they
are only available to a subset of users, and B) they can be really
annoying (especially if they don't work right).
HEY, YOU!
|
Before even thinking about using anything you see here, be
sure to take a look at these pages in both Netscape and
Internet Explorer so you know what people who don't use your
favorite browser will be seeing.
|
Netscapisms
Blink!
Want to get someone's attention?
Just in case that isn't annoying enough,
The blink rate seems pretty slow on my system, which is both good
news and bad news. Blinking faster would be even more annoying, but you might
get a bit more time to read the darned thing.
GIF Animations
Netscape supports a form of GIF file that contains multiple frames.
It will play the frames of the file in rapid succession, creating
a low-budget form of animation. If you want to learn more about how
to create GIF animations, see
CyberNet.
This is a relatively safe Netscapism to use, since other browsers
will still see the first frame and get the basic idea of the image
without motion.
Frames
Frames let you create HTML pages that are presented in multiple windows
in a browser. For example, you might create an Explorer-like view that
consists of two windows side-by-side.
The left one would be a tree view of something,
and when you clicked on an item there it would be displayed in the
right window.
Besides being Netscape 2.0-specific, frames are pretty complicated. If you
want to learn more about them, get a book or check out Netscape's web
site. I won't explain them here.
Java
Java is a C-like programming language. It's way beyond this group of
pages to explain, but suffice it to say that you'll need a Java compiler
and programming experience before you could tackle creating a Java
application.
JavaScript
Netscape has a simple scripting language in its browser that they used to
call LiveScript until they figured it would get more attention if it had
the term "Java" in it. It lets you do a few cool things, but again it
only works on Netscape at the moment.
Internet Explorerisms
Microsoft couldn't leave well enough alone either. They've added a few
of their own features to HTML. You should be even less tempted to use
these than the Netscape features, because Internet Explorer is probably
less than 10 percent of the total browser market right now. If you do
use any of these, make sure they still look reasonable in Netscape.
Background Sounds
If you started this page with Internet Explorer and have a sound board,
you've been listening to music. It's done with the IE-specific code
<BGSOUND SRC="hawaii50.mid">
inside the file. The file can be either
a MIDI file or a WAV file. Other browsers or systems without a sound
board will just "silently" ignore BGSOUND.
If you must use this, try to keep your music short and subtle.
IE doesn't provide a way to stop playing the sound, short of turning
all sound off in IE's View/Options dialog, so if someone doesn't like
your choice of music they don't have a lot of options and will be
very annoyed.
Marquees
Like Netscape's GIF animations, IE's marquees bring econo-animation to
web pages. They can be just as annoying if overused. Plus, they don't
degrade all that gracefully in Netscape, which is still the most common
browser by far. For best Netscape-degradation, don't depend on anything
but the standard font and stick with dark text, since the background
won't happen if MARQUEE isn't supported.
Here are a few examples of marquees. Note that you can only scroll text
with a marquee, but you can get some symbols by using a font change
to Wingdings.
DANGER!
Background Colors in Tables
IE supports the BGCOLOR option in the TABLE, TR, or TD tags, so
you have a lot of control over how your tables are shaded. I've used that
feature in many tables in this tutorial, notice that table background
effects don't show up in Netscape.
You can also use an unfilled table entry for special effects,
like this multicolor raised horizontal rule:
It's probably better in most cases to use a bitmap
for a trick like this since that will work with Netscape too.
You can use a WIDTH option to the IMG tag to stretch the bitmap and it
will still look good.
Font Faces
In these pages, I've made liberal use of the FACE extension
that IE provides to the FONT code. It's mighty handy to have, especially for characters
like Wingdings. But remember that not everyone will have the fonts
that you have, so they may see something very different than you do.
If you stick to the standard Windows fonts like
Times New Roman,
Arial,
Courier New,
Symbol (
ABCDabcd
) and Wingdings (
CDEFJKLMNxi²■╢
), you will probably be OK on Windows.
However, the most universal way to do small graphics is with GIFs.
Don't forget that if you need a fixed-pitch font like Courier there's
a universal way to get that with the
<KBD> ... </KBD> pairing.
Don't use a browser-specific method when a better solution is available.
AVI files
Normally you think of AVI files as being big honking multi-megabyte
monsters. But if you make the graphic small and use a tiny palette
you can create some nice animations that don't take up that much
space. This animation of a Porche is a 64KB AVI file. Small icon-sized
animations can be as little as 10KB.
You lay out an AVI file using the IMG tag, but specify the AVI
file name with the DYNSRC parameter. In the same tag, you can
still include a GIF file with the familiar SRC parameter.
That would be used on browsers that don't support AVI (Netscape and the
rest of the world right now). Since Netscape supports multi-frame GIFs
you could use one of those and get motion effects for both browsers!
[Go back to Contents page]
Copyright ⌐ 1996 CMP Publications Inc.